#include<bits/stdc++.h>
#include<bits/extc++.h>
using namespace std;
using namespace __gnu_pbds;
const int base = 131;
const long long mod = 1000000000000000031,mod2 = 999999999999999989;
int n,k;
long long a,b;
char s[30000011];
int cnt[1000011][26];
char nxt[1000011];
gp_hash_table<long long,int> lst;
long long mi,H;
int L,R,K;
char res[10000011];
int main()
{
	ios::sync_with_stdio(false);
	cin.tie(0),cout.tie(0);
	freopen("string.in","r",stdin);
	freopen("string.out","w",stdout);
	cin >> n >> k >> a >> b;
	cin >> s;
	for(int i = n;i;i--) s[i] = s[i - 1];
	mi = 1;
	for(int i = 1;i <= k;i++)
		mi = (__int128)mi * base % mod;
	for(int i = 1;i <= k;i++)
		H = ((__int128)H * base + s[i]) % mod;
	for(int i = k + 1;i <= n;i++)
	{
		lst[H] = i - 1;
		cnt[i - 1][s[i] - 'a']++;
		H = (((__int128)H * base + s[i]) % mod + mod - (__int128)s[i - k] * mi % mod) % mod;
		memcpy(cnt[i],cnt[lst[H]],sizeof(cnt[i]));
	}
	nxt[0] = 'a';
	for(int i = k;i <= n;i++)
	{
		nxt[i] = 'a';
		for(char x = 'b';x <= 'z';x++) if(cnt[i][x - 'a'] > cnt[i][nxt[i] - 'a'])
			nxt[i] = x;
	}
	for(int i = n + 1;1;i++)
	{
		int p = lst[H];
		lst[H] = i - 1;
		if(p >= n)
		{
			s[i] = s[p + 1];
			L = p + 2,R = i,K = R - L + 1;
			break;
		}
		s[i] = nxt[p];
		H = (((__int128)H * base + s[i]) % mod + mod - (__int128)s[i - k] * mi % mod) % mod;
	}
	// cerr << L << " " << R << "\n";
	if(b <= R)
	{
		for(int i = a;i <= b;i++)
			cout << s[i];
		return 0;
	}
	while(a < L)
		cout << s[a++];
	for(int i = L;i <= R;i++)
		res[i % K] = s[i];
	while(a <= b)
		cout << res[(a++) % K];
	return 0;
}
//�ҵ� R ��ǰһ�γ��F�����ǰһ�γ��F�o�������ַ���������ϵģ�����ֱ�����@���o�������ַ����У����涼ֱ���ǂ�ѭ�h��  
